package com.ruoyi.remoteService;

import com.ruoyi.common.Coupon;
import com.ruoyi.common.core.constant.SecurityConstants;
import com.ruoyi.common.core.constant.ServiceNameConstants;
import com.ruoyi.common.core.domain.R;

import com.ruoyi.common.security.annotation.RequiresPermissions;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestHeader;

@FeignClient(contextId = "remoteMerchantService", value = ServiceNameConstants.MERCHANT_SERVICE)
public interface CouponRemoteService {

    @GetMapping(value = "/coupon/internal/{id}")
    public R<Coupon> getInfo(@PathVariable("id") Long id, @RequestHeader(SecurityConstants.FROM_SOURCE) String source);
}
